<!DOCTYPE html>
<html lang="zh_CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>京东顶部导航条</title>
    <link rel="stylesheet" href="../css/reset.css">
    <!-- 引入图标字体 -->
    <link rel="stylesheet" href="../css/all.css">
    <style>
        .clearfix::before,
        .clearfix::after {
            content: '';
            display: table;
            clear: both;
        }

        body {
            /* 设置字体样式 */
            font: 12px/1.5 Microsoft YaHei, Heiti SC, tahoma, arial, Hiragino Sans GB, "\5B8B\4F53", sans-serif;
        }

        .top-bar-wrapper {
            width: 100%;
            /* 设置行高 */
            height: 30px;
            background-color: #E3E4E5;
            line-height: 30px;
            /* 设置下边块 */
            border-bottom: 1px #ddd solid
        }

        .top-bar {
            /* 固定宽度 */
            width: 1190px;
            /* 水平居中 */
            margin: 0 auto;
        }

        .top-bar a,
        .top-bar span,
        .top-bar i {
            color: #999;
            text-decoration: none;
            position: relative;
        }

        .top-bar a:hover,
        .top-bar a.highlight {
            color: #f10125;
        }

        /* 设置location的位置 */
        .location {
            float: left;
        }

        /* 设置location下的图标 */
        .location .fa {
            color: #f10215;
        }

        /* 设置城市列表 */
        .location .city-list {
            display: none;
            width: 320px;
            height: 436px;
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            /* 设置绝对定位，使其不占据页面的位置 */
            position: absolute;
            top: 31px;
            z-index: 999;
            box-shadow: 0 2px 2px rgba(0, 0, 0, 0);
        }
        .location:hover .city-list {
            display: block;
        }

        .current-city {
            padding: 0 10px;
            border: 1px solid transparent;
            border-bottom: none;
            position: relative;
            z-index: 9999;
        }

        /* 设置current-city的移入效果 */
        .location:hover .current-city {
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            border-bottom: none;
            padding-bottom: 1px;
        }

        /* 设置shortcut */
        .shortcut {
            float: right;
        }

        /* 设置分隔线 */
        .shortcut .line {
            width: 1px;
            height: 10px;
            background-color: #999;
            margin: 10px 12px 0;
        }

        .shortcut li {
            float: left;
        }

        /* ********************************* */
        .myJD .myJD-list {
            display: none;
            width: 280px;
            height: 161px;
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            /* 设置绝对定位，使其不占据页面的位置 */
            position: absolute;
            top: 31px;
            z-index: 999;
            box-shadow: 0 2px 2px rgba(0, 0, 0, 0);
        }

        .myJD:hover .myJD-list {
            display: block;
        }
        .myJD-head {
            padding: 0 10px;
            border: 1px solid transparent;
            border-bottom: none;
            position: relative;
            z-index: 9999;
        }
        .myJD:hover .myJD-head {
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            border-bottom: none;
            padding-bottom: 1px;
        }
        /* ********************************* */
        .CP .CP-list {
            display: none;
            width: 155px;
            height: 92px;
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            /* 设置绝对定位，使其不占据页面的位置 */
            position: absolute;
            top: 31px;
            z-index: 999;
            box-shadow: 0 2px 2px rgba(0, 0, 0, 0);
        }
        .CP:hover .CP-list {
            display: block;
        }
        .CP-head {
            padding: 0 10px;
            border: 1px solid transparent;
            border-bottom: none;
            position: relative;
            z-index: 9999;
        }
        .CP:hover .CP-head {
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            border-bottom: none;
            padding-bottom: 1px;
        }
        /* ********************************** */
        .CS .CS-list {
            display: none;
            width: 170px;
            height: 247px;
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            /* 设置绝对定位，使其不占据页面的位置 */
            position: absolute;
            top: 31px;
            z-index: 999;
            box-shadow: 0 2px 2px rgba(0, 0, 0, 0);
        }
        .CS:hover .CS-list {
            display: block;
        }
        .CS-head {
            padding: 0 10px;
            border: 1px solid transparent;
            border-bottom: none;
            position: relative;
            z-index: 9999;
        }
        .CS:hover .CS-head {
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            border-bottom: none;
            padding-bottom: 1px;
        }
        /* ***************************** */
        .SN .SN-list {
            display: none;
            width: 1188px;
            height: 179px;
            left: 292px;
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            /* 设置绝对定位，使其不占据页面的位置 */
            position: absolute;
            top: 31px;
            z-index: 999;
            box-shadow: 0 2px 2px rgba(0, 0, 0, 0);
        }
        .SN:hover .SN-list {
            display: block;
        }
        .SN-head {
            padding: 0 10px;
            border: 1px solid transparent;
            border-bottom: none;
            position: relative;
            z-index: 9999;
        }
        .SN:hover .SN-head {
            background-color: white;
            border: 1px solid rgb(204, 204, 204);
            border-bottom: none;
            padding-bottom: 1px;
        }
    </style>
</head>

<body>
    <!-- 创建外部容器 -->
    <div class="top-bar-wrapper">
        <!-- 创建内部容器 -->
        <div class="top-bar clearfix">
            <!-- 左侧菜单 -->
            <div class="location">
                <div class="current-city">
                    <i class="fa fa-map-marker-alt"></i>
                    <a href="javascript:;">江西</a>
                </div>
                <div class="city-list">

                </div>
            </div>
            <!-- 右侧菜单 -->
            <ul class="shortcut clearfix">
                <li>
                    <a href="javascript:;">你好，请登入</a>
                    <a class="highlight" href="javascript:;">免费注册</a>
                </li>
                <!-- 分割线 -->
                <li class="line"></li>
                <li><a href="javascript:;">我的订单</a></li>
                <li class="line"></li>
                <li class="myJD">
                    <div class="myJD-head">
                        <a href="javascript:;">我的京东</a>
                        <i class="fa fa-angle-down"></i>
                    </div>
                    <div class="myJD-list">
    
                    </div>
                </li>
                <li class="line"></li>
                <li>
                    <a href="javascript:;">京东会员</a>
                </li>
                <li class="line"></li>
                <li class="CP">
                    <div class="CP-head">
                        <a class="highlight" href="javascript:;">企业采购</a>
                        <i class="fa fa-angle-down"></i>
                    </div>
                    <div class="CP-list">

                    </div>
                </li>
                <li class="line"></li>
                <li class="CS">
                    <div class="CS-head">
                        <span>客户服务</span>
                        <i class="fa fa-angle-down"></i>
                    </div>
                    <div class="CS-list">

                    </div>
                </li>

                <li class="line"></li>
                <li class="SN">
                    <div class="SN-head">
                        <span>网站导航</span>
                        <i class="fa fa-angle-down"></i>
                    </div>
                    <div class="SN-list">

                    </div>
                </li>
                <li class="line"></li>
                <li>
                    <span>手机京东</span>
                </li>
            </ul>
        </div>
    </div>
</body>

</html>